<?php

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

namespace Admin\Model;

use Think\Model;

class SeckillLeanCloudModel extends SyncModel {

    protected $tableName = "seckill";
    
    //leancloud表名
    protected $leancloudName = "Seckill";
    
    protected $_validate = array(
    );
    //映射的字段
    protected $_map = array('objectId' => 'id', 'createdAt' => 'createdate', 'updatedAt' => 'lastupdate');
    
    //leancloud 字段类型
    protected $leancloudelds = array(
        "objectId" => "String",
        "name" => "String",
        "begindate" => "Date",
        "enddate" => "Date",
        "products"=>"String",
        "createdAt" => "Date",
        "updatedAt" => "Date",
        'syncStatus' => "Number",
        "status" => "Number"
    );
    //配置字段
    protected $fields = array(
        'objectId',
        'name',
        'begindate',
        'enddate',
        'products',
        'createdAt',
        'updatedAt',
        'syncStatus',
        'status',
        '_type' => array(
            'objectId' => 'int',
            'name' => 'varchar',
            'begindate' => 'int',
            'enddate' => 'int',
            'products' => 'varchar',
            'createdAt' => 'int',
            'updatedAt' => 'int',
            'syncStatus' => 'int',
            'status' => 'int'
        )
    );
}